home *** CD-ROM | disk | FTP | other *** search
/ NetNews Offline 2 / NetNews Offline Volume 2.iso / news / comp / sys / amiga / programmer / 6183 < prev    next >
Encoding:
Text File  |  1996-08-05  |  1.6 KB  |  38 lines

  1. Newsgroups: comp.sys.amiga.programmer
  2. Path: news.ridgecrest.ca.us!usenet
  3. From: mojaveg@mojaveg.ridgecrest.ca.us (Everett M. Greene)
  4. Subject: Re: pointer conversion error
  5. X-Nntp-Posting-Host: annex027
  6. Content-Type: text/plain; charset=iso-8859-1
  7. Message-ID: <19960325.7D4A7F8.6B80@mojaveg.ridgecrest.ca.us>
  8. Sender: usenet@ridgecrest.ca.us (Ridgenet Usenet admin)
  9. Content-Transfer-Encoding: 8bit
  10. Organization: none that you'd notice
  11. X-Newssoftware: GRn 2.1 Feb 19, 1994
  12. References: <381.6657T11T967@mistral.co.uk> <Pine.A32.3.91.960324124636.16067A-100000@red.weeg.uiowa.edu>
  13. Mime-Version: 1.0
  14. Date: Mon, 25 Mar 1996 15:23:18 GMT
  15.  
  16. In article <Pine.A32.3.91.960324124636.16067A-100000@red.weeg.uiowa.edu>
  17.     The Amorphous Mass <robinson@blue.weeg.uiowa.edu> writes:
  18. > On 24 Mar 1996, Adam Atkinson wrote:
  19. > > my c compiler (SAS/C version 6.56) creates a warning about the following:
  20. > > 
  21. > >                         printf("%u %u %u \n", i, l, h);
  22. > > 
  23. > > three.c 36 Warning 104: conversion from pointer to const/volatile to 
  24. > > pointer to non-const/volatile
  25. > > What am I doing wrong? i,l and h are unsigned longs.
  26. >  That's a very curious error.  The problem seems to be that you're passing 
  27. > longs to printf and telling printf that they're ints.  Try using %lu instead 
  28. > of %u.
  29.  
  30. Notice that it's not an error, only a warning.  i, l, or h has been
  31. defined as const?
  32.  
  33.     -----------------------------------------------------------------------
  34.     Everett M. Greene   (The Mojave Greene, crotalus scutulatus scutulatus)
  35.     Ridgecrest, Ca. 93555           Path: mojaveg@ridgecrest.ca.us
  36.